<? include($real_path . "includes/inc_module_tygia.php");?>
<div class="left_banner">

<?
$sqlWhere = '';
/*if (isset($iCat))
{
	$sqlWhere .= ' AND ban_category LIKE "%[' . $iCat . ']%" ';
}*/

$db_select = new db_query('SELECT ban_id,ban_name,ban_format,ban_picture,ban_width,ban_height,ban_html,ban_target FROM banners WHERE ban_type = 2 AND ban_active = 1 ' . $sqlWhere . ' AND lang_id = ' . $lang_id . ' ORDER BY ban_order ASC');
while ($row = mysql_fetch_array($db_select->result))
{
?>
<div>
	<? if ($row['ban_format'] == 1) { // banner Ảnh?>
	<a title="<?=$row['ban_name'];?>" href="<?=$con_root_path;?>banner_click.php?iBan=<?=$row['ban_id'];?>" target="<?=$row['ban_target'];?>" rel="nofollow"><img src="/banners/<?=$row['ban_picture'];?>"></a>
    <? } elseif ($row['ban_format'] == 2) { // banner Flash?>
    <script type="text/javascript">
	AC_FL_RunContent( 'codebase','http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0',
		'width','<?=$row['ban_width'];?>',
		'height','<?=$row['ban_height'];?>',
		'title','<?=$row['ban_name'];?>',
		'src','/banners/<?=substr($row['ban_picture'],0,strrpos($row['ban_picture'],'.'));?>'
	</script>
    <? } elseif ($row['ban_format'] == 3) {// banner HTML?>
	<?=$row['ban_html']?>
	<? } else { ?>
	<?	// ko lam j ca ?>
    <? }?>
</div>
<?
}
unset($db_select);
?>
</div>